package org.gitman.agentplatform.ui.utils;

import java.awt.Color;
import java.awt.Graphics;
import java.awt.image.BufferedImage;
import java.io.IOException;

import javax.swing.JPanel;



public class ImagePanel extends JPanel{
	
	private BufferedImage image;
	
	public ImagePanel(String imageName){
		super();		
		setBackground(Color.white);
		try {
			image = ResourcesLoader.getInstance().getImage(imageName);
		} catch (IOException e) {
			e.printStackTrace();
		}
	}
	
	public void paint(Graphics g){
		super.paint(g);
		g.drawImage(image, 0, 0, null);		
	}

}
